package org.ceteca.explica.core.common;

import org.ceteca.explica.client.ClientContext;
import org.ceteca.explica.core.installer.EntityLauncher;
import org.ceteca.explica.core.installer.SubentityOT;
import org.eclipse.swt.widgets.Button;

public class SelectionSubentityOT extends SubentityOT {

	private Button button;

	private EntityLauncher subentityLauncher;



public EntityLauncher getSubentityLauncher() {
		return subentityLauncher;
	}




	public void setSubentityLauncher(EntityLauncher subentityLauncher) {
		this.subentityLauncher = subentityLauncher;
	}




	/*
	private EntityLauncher childEntityLauncher;
	


	public EntityLauncher getChildEntityLauncher() {
		return childEntityLauncher;
	}


	public void setChildEntityLauncher(EntityLauncher childEntityLauncher) {
		this.childEntityLauncher = childEntityLauncher;
	}

/*
	public SelectionSubentityOT(EntityOT subentityData, String parentFieldId,
			EntityLauncher parentEntity) {
		super(subentityData, parentFieldId, parentEntity);
		
	}
	
	
	public SelectionSubentityOT(String entityId,String subentityWidgetName, EntityLauncher parentEntityLauncher){
		super();
		this.setParentEntity(parentEntityLauncher);
		this.setParentFieldId(subentityWidgetName);
		this.setSubentityData(ClientContext.getInstance().getEntity(entityId));
	}
*/
	public SelectionSubentityOT(String entityId,String subentityWidgetName, EntityLauncher parentEntityLauncher, Button widget){
		super();
		this.setParentEntity(parentEntityLauncher);
		this.setParentFieldId(subentityWidgetName);
		this.setSubentityData(ClientContext.getInstance().getEntity(entityId));
		this.button=widget;
	}
	


	
	public String toString(){
		StringBuilder sb=new StringBuilder();
		return sb.toString();
	}


	public Button getButton() {
		return button;
	}


	public void setButton(Button button) {
		this.button = button;
	}
		
	

}
